home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / C and C++ / Compilers⁄Interps / GCC-2.3.3r12 / Tests / yucko.c < prev    next >
Encoding:
C/C++ Source or Header  |  1993-03-08  |  446 b   |  36 lines  |  [TEXT/MPS ]

  1. typedef struct s1 {
  2.   int **hdl;
  3.   short left;
  4. } S1;
  5.  
  6. typedef struct list1 {
  7.     unsigned short slot1;
  8. #ifndef __GNUC__
  9.     short right;
  10.     short unused;
  11.     S1 s1s[];
  12. #endif
  13. } List1;
  14.  
  15. typedef struct list2 {
  16.     unsigned short slot1;
  17.     short right;
  18.     short unused;
  19.     S1 s1s[0];
  20. } List2;
  21.  
  22. typedef struct list3 {
  23.     unsigned short slot1;
  24.     short right;
  25.     short unused;
  26.     S1 s1s[1];
  27. } List3;
  28.  
  29. main()
  30. {
  31.     subr(sizeof(List1));
  32.     subr(sizeof(List2));
  33.     subr(sizeof(List3));
  34. }
  35.  
  36.